package com.yang965.producer.controller;

import com.yang965.producer.kafka.boot.KafkaProducerDemo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class KafkaController {

    @Autowired
    KafkaProducerDemo kafkaProducerDemo;

    @RequestMapping("/send")
    public String send(String str) {
        kafkaProducerDemo.send(str);
        return "已处理";
    }

}
